'use strict';

var cmsUtils = angular.module('cmsUtils');

cmsUtils.factory('StringUtil', [function(){      //TODO:
    return {
        isEmpty: function (o){
            if (o === null || o === "null" || o === undefined || o === "undefined" || o === "") {
                return true;
            } else {
                return false;
            }
        }
    }
}]);

cmsUtils.factory('Util', [function(){      //TODO:
    return {

        getScreenSize: function() {
            var sh = window.screen.height;
            if (document.body.clientHeight < sh) {
                sh = document.body.clientHeight;
            }

            var sw = window.screen.width;
            if (document.body.clientWidth < sw) {
                sw = document.body.clientWidth;
            }
            return {h: sh, w:sw};
        }
    }
}]);



